Skip to content

pkgs/id crate split step 6a: WorldScopes -> id-caps, hex_encode -> id-core (#4409) - #9153

Merged
dezren39 merged 1 commit into
mainfrom
split/step6a-scopes-hex
Nov 13, 2026
Merged

dezren39 merged 1 commit into
mainfrom
split/step6a-scopes-hex

Conversation

@dezren39

@dezren39 dezren39 commented Nov 13, 2026 •

Copy link
Copy Markdown
Member

Step 6 prep for #4409 (umbrella #3447). The directory modules name exactly two things from the worlds crate — WorldScopes (the ceiling surface) and world::hex_encode. Design seam 10: id-directory must not depend on id-worlds, so both move down first, per the step 1–2 precedent.

  • WorldScopes → new id_caps::world_scopes module; id-worlds re-exports it at world::WorldScopes. allows_effects registry reference resolves inside id-caps unchanged. all_recognized becomes pub; new WorldScopes::EMPTY const replaces two direct tuple constructions in world/core.rs; test sites that built sets from raw fields now use bits()/union()/from_bits().
  • hex_encode → new id_core::hex module; world::util re-exports it, keeping crate::world::hex_encode valid for directory/directory_auth/directory_mail.

Behaviour-preserving; no call site outside the moved definitions changed meaning.

Verification (laptop, baseline at 6741fc50a4)

  • id-caps: 87 passed (baseline 87) · id-core: 386 passed + pre-existing id: frames byte-refusal test fails on main (RequestTooLarge vs BudgetExhausted) — blocks id build + nixos-integration check #8354 frames failure, identical at baseline · id-worlds: 721 passed (baseline 721) · facade cargo test -p id: 1704 passed / 0 failed / 19 ignored — identical to baseline.
  • Fuel canary: FUEL_BUDGETS diff against the baseline snapshot is empty (sandbox.rs untouched).
  • Note: main also carries a pre-existing suite-B breakage (-p id --features web,ssh does not compile: 9 web-seam visibility sites left by step 5). That is step 6c charter and is fixed there, not here; this PR does not touch it.

Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

…-core (#4409)

Prep for step 6 (id-directory): the directory modules name exactly
two things from the worlds crate, WorldScopes (the ceiling surface)
and world::hex_encode. Design seam 10 says id-directory must not
depend on id-worlds, so both move down first, following the step 1-2
precedent of shared vocabulary moving into the caps/kernel crates.

- WorldScopes moves to a new id_caps::world_scopes module. Its only
  outward reference, world_caps::PROVIDER_REGISTRY in allows_effect,
  resolves inside id-caps unchanged. id-worlds re-exports it at
  world::WorldScopes, so every existing path compiles as before.
  all_recognized becomes pub (it was pub(crate)); a named EMPTY
  constant replaces direct tuple construction at the two core.rs
  sites that used it, and test code that built sets from raw fields
  now uses bits()/union()/from_bits().
- hex_encode moves to a new id_core::hex module; world::util
  re-exports it, keeping crate::world::hex_encode valid for
  directory, directory_auth and directory_mail.

Behaviour-preserving throughout. Verification on the laptop at
6741fc5 baseline: id-caps 87 passed (baseline 87), id-core 386
passed + the pre-existing #8354 frames failure (identical at
baseline), id-worlds 721 passed (baseline 721), facade 1704 passed /
0 failed / 19 ignored (identical to baseline). FUEL_BUDGETS in
crates/id-worlds/src/sandbox.rs is byte-identical to the baseline
snapshot (diff empty); sandbox.rs is untouched by this change.
@dezren39
dezren39 requested a review from a team as a code owner November 13, 2026 01:16
@coderabbitai

coderabbitai Bot commented Nov 13, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 31 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 5af992ad-aa48-4fc3-a768-a96cdb8a49e9
Commits

Reviewing files that changed from the base of the PR and between b7cc3a8 and fafd361.

Files selected for processing: 8

  • pkgs/id/crates/id-caps/src/lib.rs
  • pkgs/id/crates/id-caps/src/world_scopes.rs
  • pkgs/id/crates/id-core/src/hex.rs
  • pkgs/id/crates/id-core/src/lib.rs
  • pkgs/id/crates/id-worlds/src/world/core.rs
  • pkgs/id/crates/id-worlds/src/world/mod.rs
  • pkgs/id/crates/id-worlds/src/world/tests.rs
  • pkgs/id/crates/id-worlds/src/world/util.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-13T01:18:26.006171Z fafd361 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@dezren39

Copy link
Copy Markdown
Member Author

Nix gate note: nix build .#id-lib compiles the full workspace with this change; its check phase fails on exactly one test, cli_tests::world_new_scaffold_compiles_with_pinned_roc (Roc compiler cache write AccessDenied inside the Nix sandbox). Verified pre-existing: a pristine build of main at 6741fc50a4 (no split changes) fails identically — same single test, same counts (93 passed / 1 failed in cli_integration). The test passes under cargo on the laptop in both the baseline and this branch (facade totals identical: 1704/0/19). So the Nix result is at parity with main; the Roc-in-sandbox failure is orthogonal to the crate split.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant